package _12interface.homework7;

public class Test {
    public static void main(String[] args) {
        Persons persons;
        persons=new Student("张三","男",18);
        persons.eat();
        System.out.println(persons.name);
        persons=new Teacher("王五","男",32);
        persons.study();
        System.out.println(persons.age);
    }
}
